console.log(Vue);

var app = new Vue({
  el: '#app',
  data: {
  	nickshow: false,
    lge: language,
    lgename: i18n.map[lang],
    account: account
  },
  methods: {
    setlanguage: function(ln){
      this.lge = i18n[ln];
      this.lgename = i18n.map[ln];
      localStorage.lang = ln;
    }
  }
})


// accordion
$(function(){
  var tabs = document.querySelectorAll('.panel-heading');
  var cons = document.querySelectorAll('.panel-collapse');

  for(var i=0; i<tabs.length; i++){
    bindtab(i)
  }

  function bindtab(index){
    tabs[index].addEventListener('click', function(){
      var bln = cons[index].getAttribute('check');
      if(bln){
        cons[index].setAttribute('check', '');
        cons[index].className = 'panel-collapse collapse';
      }else{
        clearClass();
        cons[index].setAttribute('check', '1');
        cons[index].className = 'panel-collapse collapse in';
      }
    }, !1);
  }

  function clearClass(){
    for(var i=0; i<cons.length; i++){
      cons[i].className = 'panel-collapse collapse';
      cons[i].setAttribute('check', '');
    }
  }
});
